<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreateGoodsSkuDetailTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('goods_sku_detail', function (Blueprint $table) {
            $table->bigIncrements('id');
            $table->timestamps();

            $table->string('key')->default('')->comment('属性key值');

            $table->string('value')->default('')->comment('属性value值');

            $table->integer('goods_sku_id')->default(0)->unsigned()->comment('');



        });

        DB::statement("ALTER TABLE `goods_sku_detail` COMMENT='商品sku详情表'");//表注释
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('goods_sku_detail');
    }
}
